package com.medusa.aps.business.modules.modeling.model.output;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.experimental.Accessors;

import java.util.List;

/**
 * 工艺工序设备返回结果
 *
 * @author miskw
 * @date 2023/9/1
 */
@Data
@Accessors(chain = true)
public class ProcessEquipmentVO {
    @Schema(description = "主键")
    private Integer id;
    /**
     * 设备id
     */
    @Schema(description = "设备id")
    private Long equipmentId;
    /**
     * 设备编码
     */
    @Schema(description = "设备编码")
    private String equipmentCode;
    /**
     * 生产节拍
     */
    @Schema(description = "生产节拍")
    private Long productionBeat;
    /**
     * 辅助资料id
     */
    @Schema(description = "辅助资料id")
    private Integer auxiliaryDataId;
    /**
     * 辅助资料编码
     */
    @Schema(description = "辅助资料编码")
    private String auxiliaryDataCoding;
    /**
     * 加工批量
     */
    @Schema(description = "加工批量")
    private Long processingBatch;
    /**
     * 物料id
     */
    @Schema(description = "物料id")
    private Long materialId;
    /**
     * 工艺工序id
     */
    @Schema(description = "工艺工序id")
    private Integer processProcessId;

    public void toOrderTechnologicalProcessVO(OrderTechnologicalProcessVO orderTechnologicalProcessVO, List<OrderTechnologicalProcessVO> result) {
        orderTechnologicalProcessVO.setEquipmentCode(equipmentCode)
                .setProductionBeat(productionBeat)
                .setAuxiliaryDataCoding(auxiliaryDataCoding)
                .setProcessingBatch(processingBatch);
        result.add(orderTechnologicalProcessVO);
    }
}
